<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
<title>重置期初建账</title>
<meta name="decorator" content="default" />
<script type="text/javascript">
$(document).ready(function() {
	$("#btnReset").click(function(){//审批成功
		layer.confirm('重置期初建账操作【不可逆】，所显示的数据重置后将被初始化，是否重置?', {icon: 3, title:'提示'}, function(index){
			layer.load(2);
			$("#inputForm").attr("action", "${ctx}/vaccinate/bsProduct/saveReset?success=true");
			$("#inputForm").submit();
			layer.close(index);
		});
	});
});
</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li class="active"><a href="#">重置期初建账</a></li>
	</ul>
	<sys:message content="${message}"/>
	<form:form id="inputForm" modelAttribute="bsProduct" action="${ctx}/vaccinate/bsProduct/bsProductReset" method="post" class="breadcrumb form-search">
		<ul class="ul-form">
			<li><label>单位：</label>
				<sys:treeselect2 id="storeCode" name="storeCode" value="${office.code}" labelName="storeName" labelValue="${office.name}"
					title="机构" url="/sys/office/treeData2?type=2" cssClass="input-medium" layer = "true" notAllowSelectParent="true"/>
			</li>
			<li><label>重置时间：</label>
				<input name="beginDate" type="text" maxlength="20" class="Wdate required" readonly disabled
					value="<fmt:formatDate value="${bsProduct.beginDate}" pattern="yyyy-MM-dd"/>"
					onclick="WdatePicker({dateFmt:'yyyy-MM-dd',isShowClear:true});" />
			</li>
			<li class="btns"> <button id="btnSubmit" class="btn btn-primary" type="submit">查询</button> </li>
			<li class="btns"> <button id="btnReset" class="btn btn-primary" type="button" >重置建账</button></li>
			<li class="clearfix"></li>
		</ul>
	</form:form>
	<!-- 展示需要重置的数据 -->
	<div class="container-fluid" style = "padding-top: 5px;">
		<div class="row-fluid">
		  <h4 class="text-error">【重置须知】</h4>
		  
		  <p class="text-error">1、重置期初建账，操作【不可逆】，谨慎使用此功能</p>
		  <p class="text-error">2、重置期初建账，会清空库存和当月进销存报表</p>
		  <p class="text-error">3、重置期初建账功能暂只可以重置【当前月】进销存</p>
		  <p class="text-error">4、重置后，所有之前未入库的入库单将全部入库完成</p>
		</div>
	</div>
</body>
</html>